package com.wbcs.system.component.application.report.configbean.editablereport;

import com.wbcs.config.component.application.report.ColBean;
import com.wbcs.util.Consts;

public class EditableReportUpdateDataBean extends AbsEditableReportEditDataBean
{

    public EditableReportUpdateDataBean(IEditableReportEditGroupOwnerBean owner)
    {
        super(owner);
    }

    @Override
	protected void setParamBeanInfoOfColBean(ColBean cbUpdateSrc,EditableReportParamBean paramBean,String configColProperty,String reportTypeKey)
    {
        if(Consts.COL_DISPLAYTYPE_HIDDEN.equals(cbUpdateSrc.getDisplaytype()))
        {
            //if(configColProperty.endsWith("__old")) configColProperty=configColProperty.substring(0,configColProperty.length()-"__old".length());
        }else if(!configColProperty.endsWith("__old"))
        {
            EditableReportColBean ercbeanUpdateSrc=(EditableReportColBean)cbUpdateSrc.getExtendConfigDataForReportType(reportTypeKey);
            ercbeanUpdateSrc.setEditableWhenUpdate(2);
        }
        paramBean.setParamname(configColProperty);
    }
}
